home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 3371 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1018 b 

  1. Path: news.itd.umich.edu!clahey
  2. From: clahey@rep00703.reshall.umich.edu (Chris Lahey)
  3. Newsgroups: comp.lang.c
  4. Subject: Re: a dump question from a novice C programmer
  5. Date: 28 Jan 1996 10:36:42 GMT
  6. Organization: University of Michigan
  7. Message-ID: <CLAHEY.96Jan28103643@rep00703.reshall.umich.edu>
  8. References: <jyli-2801960040100001@li.gsfc.nasa.gov>
  9. NNTP-Posting-Host: rep00703.reshall.umich.edu
  10. In-reply-to: jyli@climate.gsfc.nasa.gov's message of Sun, 28 Jan 1996 00:40:10
  11.     -0500
  12.  
  13.  
  14. >   for (iv=0; iv < specp->nlvars; iv++)
  15.  
  16. >   what does this symbol "->" mean? I've looked all over my C books,  could
  17. >   not find anything on it. 
  18.  
  19. -> is listed in the textbook I have as the indirect selection operator.
  20. It has two operands, one on either side.  The left operand has to be a 
  21. pointer to a structure and the right operand must be a member of said
  22. structure.  specp is a pointer to a structure and nlvars is one of the
  23. members of that structure.  specp->nlvars is equivelent to
  24. (*specp).nlvars.
  25.  
  26.    Good luck,
  27.    Chris
  28.